package cn.redsoft.wechatapi.msg.resp.passivity;

import cn.redsoft.wechatapi.common.util.MsgTypeConverter;

import com.thoughtworks.xstream.annotations.XStreamAlias;
import com.thoughtworks.xstream.annotations.XStreamConverter;

public abstract class PassivityResponseMsg {
	@XStreamAlias("ToUserName")
	protected String toUserName;
	@XStreamAlias("FromUserName")
	protected String fromUserName;
	@XStreamAlias("CreateTime")
	protected long createTime;

	@XStreamAlias("MsgType")
	@XStreamConverter(value = MsgTypeConverter.class)
	protected PassivityResponseMsgType msgType;

	public PassivityResponseMsg() {
		super();
	}

	public PassivityResponseMsg(String toUserName, String fromUserName,
			long createTime, PassivityResponseMsgType msgType) {
		super();
		this.toUserName = toUserName;
		this.fromUserName = fromUserName;
		this.createTime = createTime;
		this.msgType = msgType;
	}

	public String getToUserName() {
		return toUserName;
	}

	public void setToUserName(String toUserName) {
		this.toUserName = toUserName;
	}

	public String getFromUserName() {
		return fromUserName;
	}

	public void setFromUserName(String fromUserName) {
		this.fromUserName = fromUserName;
	}

	public long getCreateTime() {
		return createTime;
	}

	public void setCreateTime(long createTime) {
		this.createTime = createTime;
	}

	public PassivityResponseMsgType getMsgType() {
		return msgType;
	}

	public void setMsgType(PassivityResponseMsgType msgType) {
		this.msgType = msgType;
	}

	@Override
	public String toString() {
		return "PassivityResponseMsg [toUserName=" + toUserName
				+ ", fromUserName=" + fromUserName + ", createTime="
				+ createTime + ", msgType=" + msgType + "]";
	}

}
